{{form()}}
<div class="center-block text-center">
    <div id="image-block">
        {% if image %}
        {{image(image.url, 'class' : 'img-responsive question-img', 'id': 'question-img')}}
        {% endif %}
    </div>
    <div id="document-block">
        {% if document %}
        <div id="document-content" data-id="{{document.id}}">
            {% if document.part > 4 %}
            {{document.content}}
            {% endif %}
        </div>
        {% endif %}
    </div>
    <div id="audio-block">
        {% if audio %}
        <button class="btn" data-url="{{audio.url}}" id="listen"><i class="fa fa-music"></i></button>
        {% endif %}
    </div>
    <div id="question-block">
        {% for question in questions %}
        <div class="question-number" data-id="{{question['id']}}">{{'Câu '~question['id']}}</div>
        {% if question['question'] %}
        <div>Question: {{ question['question'] }}</div>
        {% endif %}
        {% if question['a'] %}
        <div><input name="answer[{{question['id']}}]" id="answera{{question['id']}}" type="radio"  value="A"/>A: {{ question['a'] }}</div>
        {% endif %}
        {% if question['b'] %}
        <div><input name="answer[{{question['id']}}]" id="answerb{{question['id']}}" type="radio" value="B"/>B: {{ question['b'] }}</div>
        {% endif %}
        {% if question['c'] %}
        <div><input name="answer[{{question['id']}}]" id="answerc{{question['id']}}" type="radio" value="C"/>C: {{ question['c'] }}</div>
        {% endif %}
        {% if question['d'] %}
        <div><input name="answer[{{question['id']}}]" id="answerd{{question['id']}}" type="radio" value="D"/>D: {{ question['d'] }}</div>
        {% endif %}
        {% endfor %}
    </div>
    <button name="check" id="btn-check" type="button" class="btn btn-success"><i class="fa fa-check"></i></button>
    <button name="submit" class="btn"><i class="fa fa-arrow-right"></i></button>

    <div class="fb-comments" data-href="{{'http://localhost'~url('practice/'~qtsStr)}}" data-numposts="5" data-colorscheme="light"></div>
</div>
{{endform()}}

{{javascript_include('js/soundjs/soundjs-0.5.2.min.js')}}
{{javascript_include('js/exercise.js')}}